﻿@{
    ViewBag.Title = "Ajouter des utilisateurs";
    ViewBag.Message = "STK FJKM Ambavahadimitafo";
    var bd_confirm = ViewBag.Res;
}
@section erreur{
    <div id="image_erreur"></div>
}
@section featured {
    <section class="featured">
        <div class="content-wrapper">
            <hgroup class="title">                
                <h2>@ViewBag.Message</h2>
            </hgroup>
            <p>
                "Hitory ny Anaranao amin'ny rahalahiko aho..." Sal 22,22a
            </p>
        </div>
    </section>
}
<h2>Bienvenue dans la page d'administration</h2>
<span>Retour au </span><a href="/Admin">menu principale</a><br />   
@if (bd_confirm != null && bd_confirm == "1")
{
    <span>Inscription réussie</span><br />
}
@using(Html.BeginForm("ImportFile","Admin",FormMethod.Post,new{id="form_file"}))
 {
    <div id="i" style="width:400px;">
       <h3 id="ii">Cliquer pour importer un fichier excel</h3>
        <div id="fileType"></div>
         <input type="file" name="import_file" hidden="hidden" id="import_file"/>
    </div> 
    <div id="load"></div>       
} 
@using(Html.BeginForm("UserAdmin","Admin",FormMethod.Post,new {id="form_"}))
{
                <fieldset>
            <legend>Fiche d'inscription</legend>
            <div id="tof" style="width:198px;height:168px;float:right;border:1px solid black;overflow:hidden;">
                <img src="@Url.Content("~/TEMP_PHOTOS/no_image.jpg")" alt="Votre photos de profil" title="Ajouter avatar" />
                <div class="image_size"></div>
                <input type="file" name="tof_file" id="tof_file" style="display:none;"/>
            </div>
            <label for="Nom">Nom <span style="color:red;">*</span></label><input type="text" id="Nom" name="Nom" value="" placeholder="Iza no anaranao?" required/><br />
            <label for="Prenom">Prenom <span style="color:red;">*</span></label><input type="text" id="Prenom" name="Prenom" value="" placeholder="Iza no fanampin'anaranao?" required /><br />
            <label for="date_naissance">Date de naissance <span style="color:red;">*</span></label><input type="date" id="date_naissance" name="date_naissance" required/><br />
            <label for="adresse">Adresse</label><input type="text" id="adresse" name="adresse" placeholder="Aiza no mipetraka?" /><br />
            <label for="email">E-mail</label><input type="email" id="email" name="email" placeholder="Adiresy mailaka" /><br />
            <label for="telephone">Telephone</label><input type="tel" id="telephone" name="telephone" placeholder="Firy ny nomerao finday" /><br />
            <label for="description">A propos <span style="color:red;">*</span></label><textarea cols="150" rows="10" id="description" name="description" placeholder="Inona no talenta anananao?" required></textarea><br />
            <label for="antony">Pourquoi <span style="color:red;">*</span></label><textarea cols="150" rows="10" id="antony" name="antony" placeholder="Inona no antony nidiranao STK" required></textarea><br />
        </fieldset> 
        <input type="submit" value="S'inscrire" name="inscription" />
}
@section scripts{
   <script type="text/javascript" src="@Url.Content("~/Scripts/Script_view/AdminIndexAjout.js")"></script>
   <script>
            var ur = '@Url.Action("ImportPhotos")';
            var chemin = '@Url.Content("~/TEMP_PHOTOS/")';
            var import_file = '@Url.Action("ImportFile")';
       var image_load = '@Url.Content("~/Images/ajax-loader.gif")';
       var image = '<img id="ajax_image" src="' + image_load + '" alt="loading" />';
            a(ur,chemin,import_file,image_load,image);
        </script>       
}
@section css{
        <link rel="stylesheet" href="@Url.Content("~/Content/AdminIndexAjout.css")" />
}  